﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using PhanMemDoVui.DataAccess;
using PhanMemDoVui.BusinessObject;

namespace PhanMemDoVui.BusinessLogic
{
    class AdminBUS : UserBUS
    {
        private static AdminBUS _instance;
#region Constructor
        protected AdminBUS()
        {
            pr = null;
            state = false;
            type = true;
        }
#endregion
#region Instance
        public static AdminBUS Instance()
        {
            if (_instance == null)
                _instance = new AdminBUS();
            return _instance;
        }
#endregion
#region DuyetCauHoi
        // Chi co Admin moi duoc quyen duyet cau hoi do nguoi khac tao
        public DataTable DuyetCauHoi()
        {
            string sql = "Select Question, Ans1, Ans2, Ans3, Ans4, R_Ans, Difficulty, Created_by "
                +"From QuestnAns Where MaBank = 'Temp'";
            ConnectData conn = new ConnectData();
            return conn.GetDataTable(sql);
        }
#endregion
    }
}
